package com.service;

import com.bean.LoginInfo;
import com.dao.UserDao;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class UserService {

    @Resource
    UserDao userDao;

    public boolean checkUser(String username, String password) {
        return userDao.checkUser(username, password);
    }

    public void insertLoginInfo(LoginInfo loginInfo) {
        userDao.insertLoginInfo(loginInfo);
    }

    public List<LoginInfo> getLoginInfo(String name) {
        return userDao.getLoginLog(name);
    }

}
